from django.contrib import admin
from django.urls import path
from apps.user import views
urlpatterns = [
    # 用户名
    path('usernames/<username:username>/count/', views.UsernameCount.as_view()),
    # 手机号
    path('mobiles/<mobile:mobile>/count/', views.MobileCount.as_view()),
    # 用户注册
    path('register/', views.UserRegisterView.as_view()),
    # 用户登录
    path('login/', views.UserLoginView.as_view()),
    # 用户退出
    path('logout/', views.UserLogoutView.as_view()),
    # 用户中心数据
    path('info/', views.UserInfoView.as_view()),
    # 用户邮箱添加
    path('emails/', views.UserEmailAddView.as_view()),
    # 用户邮箱验证
    path('emails/verification/', views.UserEmailCleckView.as_view()),
    # 展示地址
    path('addresses/', views.UserAddressLookView.as_view()),
    # 新增地址
    path('addresses/create/', views.UserAddressCreateView.as_view()),
    # 修改用户地址
    path('addresses/<int:address_id>/', views.UserAddressModifyView.as_view()),
    # 设置用户默认地址
    path('addresses/<int:address_id>/default/', views.UserAddressDefaultView.as_view()),
    # 修改地址标题栏
    path('addresses/<int:address_id>/title/', views.UserAddressTitleView.as_view()),
    # 修改密码
    path('password/', views.UserPasswordUpdateView.as_view()),
]
